import datetime
i=input()
j=i[6:10]
k=datetime.datetime.now().year
print('你出生于{}年{}月{}日'.format(j,i[10:12],i[12:14]))
print('你今年{:d}周岁'.format(k-int(j)-1))
if i[-2] in ['1','3','5','7','9']:
    print('你的性别为男')
else:
    print('你的性别为女')